package com.ys.entity.logistics;

import java.util.Date;
import javax.persistence.Table;
import com.alibaba.fastjson.annotation.JSONField;
import com.ys.annotation.YsField;
import com.ys.entity.base.BaseEntity;
/**
*/
@Table(name="TL_CustomsDeclarationInvoice", catalog="Id")
public class TlCustomsDeclarationInvoice extends BaseEntity<TlCustomsDeclarationInvoice> {

	@YsField(nameDataBase="Id", nameJava="id", typeDataBase="bigint")
	private Long id;
	@YsField(nameDataBase="Pid", nameJava="pid", typeDataBase="bigint")
	private Long pid;
	@YsField(nameDataBase="Pbid", nameJava="pbid", typeDataBase="varchar")
	private String pbid;
	@YsField(nameDataBase="InvoiceOffsetItemId", nameJava="invoiceOffsetItemId", typeDataBase="bigint")
	private Long invoiceOffsetItemId;
	@YsField(nameDataBase="DeductQuantity", nameJava="deductQuantity", typeDataBase="int")
	private Integer deductQuantity;
	@YsField(nameDataBase="DeductBeforeQuantity", nameJava="deductBeforeQuantity", typeDataBase="int")
	private Integer deductBeforeQuantity;
	@YsField(nameDataBase="DeductQuantityByNo", nameJava="deductQuantityByNo", typeDataBase="int")
	private Integer deductQuantityByNo;
	@YsField(nameDataBase="NumDecCustomByInvoice", nameJava="numDecCustomByInvoice", typeDataBase="int")
	private Integer numDecCustomByInvoice;
	@YsField(nameDataBase="InvoiceSurplusNum", nameJava="invoiceSurplusNum", typeDataBase="int")
	private Integer invoiceSurplusNum;
	@YsField(nameDataBase="DeductQuantityByAfter", nameJava="deductQuantityByAfter", typeDataBase="int")
	private Integer deductQuantityByAfter;
	@YsField(nameDataBase="DeductStatus", nameJava="deductStatus", typeDataBase="tinyint")
	private Integer deductStatus;
	@YsField(nameDataBase="Status", nameJava="status", typeDataBase="tinyint")
	private Integer status;
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@YsField(nameDataBase="CreateTime", nameJava="createTime", typeDataBase="datetime")
	private Date createTime;
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@YsField(nameDataBase="UpdateTime", nameJava="updateTime", typeDataBase="datetime")
	private Date updateTime;

	public Long getId() {
		return id;
	}
	public TlCustomsDeclarationInvoice setId(Long id) {
		this.id = id;
		return this;
	}
	public Long getPid() {
		return pid;
	}
	public TlCustomsDeclarationInvoice setPid(Long pid) {
		this.pid = pid;
		return this;
	}
	public String getPbid() {
		return pbid;
	}
	public TlCustomsDeclarationInvoice setPbid(String pbid) {
		this.pbid = pbid;
		return this;
	}
	public Long getInvoiceOffsetItemId() {
		return invoiceOffsetItemId;
	}
	public TlCustomsDeclarationInvoice setInvoiceOffsetItemId(Long invoiceOffsetItemId) {
		this.invoiceOffsetItemId = invoiceOffsetItemId;
		return this;
	}
	public Integer getDeductQuantity() {
		return deductQuantity;
	}
	public TlCustomsDeclarationInvoice setDeductQuantity(Integer deductQuantity) {
		this.deductQuantity = deductQuantity;
		return this;
	}
	public Integer getDeductBeforeQuantity() {
		return deductBeforeQuantity;
	}
	public TlCustomsDeclarationInvoice setDeductBeforeQuantity(Integer deductBeforeQuantity) {
		this.deductBeforeQuantity = deductBeforeQuantity;
		return this;
	}
	public Integer getDeductQuantityByNo() {
		return deductQuantityByNo;
	}
	public TlCustomsDeclarationInvoice setDeductQuantityByNo(Integer deductQuantityByNo) {
		this.deductQuantityByNo = deductQuantityByNo;
		return this;
	}
	public Integer getNumDecCustomByInvoice() {
		return numDecCustomByInvoice;
	}
	public TlCustomsDeclarationInvoice setNumDecCustomByInvoice(Integer numDecCustomByInvoice) {
		this.numDecCustomByInvoice = numDecCustomByInvoice;
		return this;
	}
	public Integer getInvoiceSurplusNum() {
		return invoiceSurplusNum;
	}
	public TlCustomsDeclarationInvoice setInvoiceSurplusNum(Integer invoiceSurplusNum) {
		this.invoiceSurplusNum = invoiceSurplusNum;
		return this;
	}
	public Integer getDeductQuantityByAfter() {
		return deductQuantityByAfter;
	}
	public TlCustomsDeclarationInvoice setDeductQuantityByAfter(Integer deductQuantityByAfter) {
		this.deductQuantityByAfter = deductQuantityByAfter;
		return this;
	}
	public Integer getDeductStatus() {
		return deductStatus;
	}
	public TlCustomsDeclarationInvoice setDeductStatus(Integer deductStatus) {
		this.deductStatus = deductStatus;
		return this;
	}
	public Integer getStatus() {
		return status;
	}
	public TlCustomsDeclarationInvoice setStatus(Integer status) {
		this.status = status;
		return this;
	}
	public Date getCreateTime() {
		return createTime;
	}
	public TlCustomsDeclarationInvoice setCreateTime(Date createTime) {
		this.createTime = createTime;
		return this;
	}
	public Date getUpdateTime() {
		return updateTime;
	}
	public TlCustomsDeclarationInvoice setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
		return this;
	}

	public static TlCustomsDeclarationInvoice tlCustomsDeclarationInvoice(
		Long pid,
		String pbid,
		Long invoiceOffsetItemId,
		Integer deductQuantity,
		Integer deductBeforeQuantity,
		Integer deductQuantityByNo,
		Integer numDecCustomByInvoice,
		Integer invoiceSurplusNum,
		Integer deductQuantityByAfter,
		Integer deductStatus,
		Integer status
			) {
		TlCustomsDeclarationInvoice entity = new TlCustomsDeclarationInvoice();
		entity.setPid(pid);
		entity.setPbid(pbid);
		entity.setInvoiceOffsetItemId(invoiceOffsetItemId);
		entity.setDeductQuantity(deductQuantity);
		entity.setDeductBeforeQuantity(deductBeforeQuantity);
		entity.setDeductQuantityByNo(deductQuantityByNo);
		entity.setNumDecCustomByInvoice(numDecCustomByInvoice);
		entity.setInvoiceSurplusNum(invoiceSurplusNum);
		entity.setDeductQuantityByAfter(deductQuantityByAfter);
		entity.setDeductStatus(deductStatus);
		entity.setStatus(status);
		return entity;
	}
}